	
/****** Object:  Stored Procedure BulkOrdersUpdate    Script Date: Thursday, February 21, 2008 ******/
if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[spBulkOrdersUpdate]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)
drop procedure [spBulkOrdersUpdate]
GO

	
	

	
/******************************************************************************
**		File: 
**		Name: spBulkOrdersUpdate
**		Desc: 
**
**		Return values:
** 
**		Called by:   
**              
**		Parameters:
**		Input							Output
**     ----------							-----------
**
**		Auth: CodeSmith
**		Date: 2/21/2008 2:16:34 AM
*******************************************************************************
**		Change History
*******************************************************************************
**		Date:		Author:				Description:
**		--------		--------				-------------------------------------------
**    
*******************************************************************************/
CREATE PROCEDURE spBulkOrdersUpdate
	@BulkOrderID int, 
	@OrderDate datetime, 
	@Type tinyint, 
	@ProductCode varchar(10), 
	@Description nvarchar(50), 
	@Color nvarchar(10), 
	@StartDate datetime, 
	@TotalQtyOrdered int, 
	@TotalQtyCompleted int, 
	@TotalQtyInProgressBelow50P int, 
	@TotalQtyInProgressAbove50P int, 
	@EstimatedDate datetime, 
	@StockLastCheckedDate datetime, 
	@StockLastCheckedQty int, 
	@FOB money, 
	@CompletedDate datetime, 
	@SupplierCode varchar(3), 
	@Owner int, 
	@Catalogue nvarchar(9), 
	@Page varchar(3), 
	@Pack varchar(9), 
	@PackQty int, 
	@CatalogID int, 
	@Target bit, 
	@SalesDescription1 nvarchar(40), 
	@SalesDescription2 nvarchar(40), 
	@StockLocation varchar(3), 
	@AvailableInUSA bit, 
	@BONo varchar(6), 
	@MinOrderQty varchar(30), 
	@TallPaletQty varchar(30), 
	@IDSSortID int, 
	@IsArchived bit, 
	@CatPackDesc varchar(9), 
	@MUKTHGCatPackQty int, 
	@MUKTHGCatPackDesc varchar(9), 
	@HomeDelivered15Price money, 
	@CurrencyID int, 
	@IsShownInLGDCatalog bit, 
	@SpecialOfferDisc money, 
	@ModifiedDate datetime 
AS

UPDATE [BulkOrders] SET
	[OrderDate] = @OrderDate,
	[Type] = @Type,
	[ProductCode] = @ProductCode,
	[Description] = @Description,
	[Color] = @Color,
	[StartDate] = @StartDate,
	[TotalQtyOrdered] = @TotalQtyOrdered,
	[TotalQtyCompleted] = @TotalQtyCompleted,
	[TotalQtyInProgressBelow50P] = @TotalQtyInProgressBelow50P,
	[TotalQtyInProgressAbove50P] = @TotalQtyInProgressAbove50P,
	[EstimatedDate] = @EstimatedDate,
	[StockLastCheckedDate] = @StockLastCheckedDate,
	[StockLastCheckedQty] = @StockLastCheckedQty,
	[FOB] = @FOB,
	[CompletedDate] = @CompletedDate,
	[SupplierCode] = @SupplierCode,
	[Owner] = @Owner,
	[Catalogue] = @Catalogue,
	[Page] = @Page,
	[Pack] = @Pack,
	[PackQty] = @PackQty,
	[CatalogID] = @CatalogID,
	[Target] = @Target,
	[SalesDescription1] = @SalesDescription1,
	[SalesDescription2] = @SalesDescription2,
	[StockLocation] = @StockLocation,
	[AvailableInUSA] = @AvailableInUSA,
	[BONo] = @BONo,
	[MinOrderQty] = @MinOrderQty,
	[TallPaletQty] = @TallPaletQty,
	[IDSSortID] = @IDSSortID,
	[IsArchived] = @IsArchived,
	[CatPackDesc] = @CatPackDesc,
	[MUKTHGCatPackQty] = @MUKTHGCatPackQty,
	[MUKTHGCatPackDesc] = @MUKTHGCatPackDesc,
	[HomeDelivered15Price] = @HomeDelivered15Price,
	[CurrencyID] = @CurrencyID,
	[IsShownInLGDCatalog] = @IsShownInLGDCatalog,
	[SpecialOfferDisc] = @SpecialOfferDisc,
	[ModifiedDate] = @ModifiedDate
WHERE
	[BulkOrderID] = @BulkOrderID

GO
